# Contributor: Lucas Ramage <ramage.lucas@protonmail.com>
# Maintainer: Lucas Ramage <ramage.lucas@protonmail.com>
pkgname=ecl
pkgver=21.2.1
pkgrel=2
pkgdesc="Embeddable Common Lisp"
arch="all"
url="https://common-lisp.net/project/ecl"
options="!check"
license="LGPL-2.1-or-later"
makedepends="gmp-dev libffi-dev gc-dev texinfo"
source="https://common-lisp.net/project/ecl/static/files/release/ecl-$pkgver.tgz
	fix-integer-suffixes.patch
	"
subpackages="$pkgname-doc $pkgname-dev"

prepare() {
	default_prepare

	update_config_sub
	update_config_guess
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--infodir=/usr/share/info \
		--mandir=/usr/share/man \
		--localstatedir=/var/state/ecl \
		--enable-boehm=system \
		--with-cxx
	make -j1
}

package() {
	make DESTDIR="$pkgdir" install
}
sha512sums="
0849bebe1a8073ea8027cfb172c1d7781d43adb6a8b80585bd08d5674b80422d1648b6fbf718cc17a51c5de6c696514523b4d13a82e8113bf9365c95d3c28648  ecl-21.2.1.tgz
aa739683f6256f282eecf79907efb5eac11bd97bd04c5e7cf1ca935e78c9d27d8728b11ad3dbde1250a73ed9bf1aaf4f545bce5541a8139bc18753c41bdbfc17  fix-integer-suffixes.patch
"
